#pragma once

#include "stream2frame.h"
#include <iostream>
#include <string>
#include <sstream>
#include <fstream>
#include <math.h>
#include <vector>
#include <cstdlib>

using namespace std;

class simulator
{
public:
	simulator(const S2F_config_t* config, int senderBufferSize, int receiverBufferSize);
	~simulator();

	int getSenderData(unsigned char* data, int size) {}
	int getReceiverData(unsigned char* data, int size) {}

	void sim0(void);
	void sim1(void);

//	int sim1(unsigned char* send, int length, unsigned char* rec, int size);
//	int sim2(int count, int length, int sendRate);
	//void sim3(int count, int maxLength, int sendSpeed);
	//void sim4(int count, int maxLength);

private:
	vector<unsigned char> genData(int size);
	void logStr(char color, std::string str);
	string int2Str(int num);
	string data2Str(unsigned char* data, int length);

private:
	S2F_sender_t* sender;
	S2F_receiver_t *receiver;
};

